<template>
  <div class="new">
      <h1>新闻列表</h1>
  </div>
</template>

<script>
    export default {
        data(){
            return {
                list: [] //新闻数据
            }
        },
        created(){
            this.getNews()
        },
        methods: {
            getNews(){
                //获取新闻数据
                this.$http.get("api/getnewslist")
                .then(result=>{
                    if(result.body.status == 0){
                        this.list = result.body.message
                    }
                })
            }
        }
    }
</script>

<style scoped>
   

</style>

